Add an assertion and comment
authorMatthias Clasen <mclasen@redhat.com>
Mon, 27 Sep 2021 21:17:06 +0000 (17:17 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 27 Sep 2021 21:30:25 +0000 (17:30 -0400)
Maybe it helps the person unfortunate enough
to stumble in here.

gtk/gtkbuilder.c

index 6f13bde4c7c450ac1b82a2ffff865597325187d5..a151ec78cf626106142e9d8635f007e051429315 100644 (file)
@@ -606,6 +606,11 @@ gtk_builder_get_parameters (GtkBuilder         *builder,
           continue;
         }
 
+      /* At this point, property_value has been set, and we need to either
+       * copy it to one of the two arrays, or unset it.
+       */
+      g_assert (G_IS_VALUE (&property_value));
+
       if ((prop->pspec->flags & filter_flags) != 0 && filtered_parameters)
         object_properties_add (filtered_parameters, property_name, &property_value);
       else if ((prop->pspec->flags & filter_flags) == 0 && parameters)